import request from '@/utils/request'

let dev_url = process.env.VUE_APP_BASE_API
const modUrl = `member`

export default {
    /* 会员分页路径 */
    memberListPage(current, pageSize, query) {
        return request({
            url: `${modUrl}/query/page/${current}/${pageSize}`,
            method: 'get',
            params: query
        })
    },
    add(params) {
        return request({
            url: `${modUrl}/add`,
            method: 'post',
            data: params
        })
    },
    updateMember(params) {
        return request({
            url: `${modUrl}/update`,
            method: 'put',
            data:params
        })
    },
    deleteMembers(deleteIds) {
        return request({
            url: `${modUrl}/deleteByIds`,
            data:{ids:deleteIds},
            method: 'delete',
        })
    },

    queryOne(memberNo){
        return request({
            url: `${modUrl}/query/one/${memberNo}`,
            method: 'get',
        })
    },

}